<template>
  <div class="main">
    <vHeader title="购买" @return="$router.go('-1')" />
    <div class="contents">
      <div class="content">
        <img class="icon" src="~@/assets/images/success.png" />
        <div class="t1">下单成功</div>
        <div class="t2">您已下单成功，请等待卖家确认～</div>
        <div class="t1" style="margin-bottom: 15px;">购买流程</div>
        <div class="steps">
          <div class="step">
            <p>订单状态</p>
            <span>交易过程中实时留意订单状态，成交效率将影响您的信用评分。</span>
          </div>
          <div class="step">
            <p>确认交易</p>
            <span>在您未确认出售给任何用户时，对方不会收到您的任何收款信息，请及时确认。</span>
          </div>
          <div class="step">
            <p>确认收款</p>
            <span>出售时，务必确认收到款项再进行打币，未按规定操作，平台不承认任何责任。</span>
          </div>
          <div class="step">
            <p>交易完成</p>
          </div>
        </div>
        <div class="button" @click="handle">查看订单详情</div>
      </div>
    </div>
  </div>
</template>

<script>
  export default {
    data() {
      return {
        query:{}
      }
    },
    methods: {
      handle(){
        this.$router.push({
          name: 'chatRoom',
          query: this.query,
        })
      },
    },
    mounted() {
      this.query = this.$route.query
    },
  }
</script>

<style lang="scss" rel="stylesheet/scss" type="text/scss" scoped>
  .main{
    height: 100%;
    .contents{
      background: #f0f5fd;
      padding: 15px;
      height: calc(100% - 84px);
      overflow: auto;
      position: relative;
    }
  }
  .content{
    padding: 15px;
    background: #fff;
    border-radius: 8px;
    .icon{
      width: 161px;
      height: 145.5px;
      display: block;
      margin: 0 auto;
    }
    .t1{
      font-size: 14px;
      text-align: center;
      color: #444444;
      line-height: 20px;
      margin-bottom: 5px;
    }
    .t2{
      font-size: 12px;
      text-align: center;
      color: #8F949C;
      line-height: 20px;
      margin-bottom: 40px;
    }
    .button{
      line-height: 44px;
      background: #479fff;
      border-radius: 4px;
      font-size: 14px;
      color: #fff;
      text-align: center;
    }
    .steps{
      width: calc(100% - 10px);
      margin: 10px auto 40px auto;
      position: relative;
      &::before{
        content: " ";
        display: block;
        width: 1px;
        height: calc(100% - 20px);
        border-left: 1px dashed #479fff;
        position: absolute;
        top: 10px;
      }
      .step{
        padding: 0 15px;
        p{
          font-size: 14px;
          color: #479fff;
          line-height: 20px;
          position: relative;
          &::before{
            content: " ";
            display: block;
            background-image: url('../assets/images/tag.png');
            background-size: 100% 100%;
            width: 14px;
            height: 14px;
            position: absolute;
            left: -22px;
            top: 1px;
          }
        }
        span{
          font-size: 14px;
          color: #444444;
          line-height: 23px;
          display: block;
          margin-bottom: 15px;
          margin-top: 5px;
        }
      }
    }
  }
</style>
